#include <cstdio>
#include <cstring>
using namespace std;
const int maxn = 1e5+10;
char s[maxn];
int main()
{
	while(scanf("%s",s)!=EOF)
	{
		long long len = strlen(s);
		long long m,ans=0;
		scanf("%lld",&m);
		while(m--)
		{
			long long l,r;
			scanf("%lld %lld",&l,&r);
			ans += len - ((r-l)+1);
		}
		if(ans==0) printf("Bob\n");
		else
		{
			if(ans%2) printf("Alice\n");
			else printf("Bob\n");
		}
	
	}

} 
